﻿@{BlogDTO blog = ViewBag.Blog as BlogDTO;}
<!DOCTYPE html>
<html>
<head>
    <title>ScottQian</title>
    <meta name="description" content="scott qian's blog" />
    <meta name="keywords" content="qianlifeng,scottqian,blog" />
    <meta http-equiv="content-type" content="text/html; charset=utf8" />
    <link rel="stylesheet" type="text/css" href="@Url.Content("~/Themes/Simple/Styles/reset.css")" />
    <link rel="stylesheet" type="text/css" href="@Url.Content("~/Themes/Simple/Styles/main.css")" />
    <script type="text/javascript" src="@Url.Content("~/Scripts/jquery-1.5.1.min.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/Scripts/easywebui.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/Themes/Simple/Scripts/main.js")"></script>
</head>
<body>
    <div class="head">
        <div class="headC">
            <div class="headL">
                <a id="headTitle" href="@Url.Content("~/")">@blog.Title</a>
            </div>
            <div class="headR">
                @if (HttpContext.Current.User.Identity.IsAuthenticated)
                {
                    <a class="aNor" href="@Url.Action("index", "admin", null)" style="margin-right:20px;">
                        Dashboard</a>
                    <a class="aNor" href="@Url.Action("logout", "home", null)">Logout</a>
                }
                else
                {
                    <a class="aNor" href="@Url.Action("Login", "Home", null)">Login</a>
                }
            </div>
        </div>
    </div>
    <div class="content">
        <div class="cLeft">
        </div>
        <div class="cLeft fixed">
            <div class="cLeftItem selected">
                <a class="aNor" href="@Url.Content("~/")">Articles</a>
            </div>
            <div class="cLeftItem">
                <a class="aNor" href="#">Projects</a>
            </div>
            <div class="cLeftItem ">
                <a class="aNor" href="http://about.me/scottqian">About Me</a>
            </div>
        </div>
        <div class="cCenter">
            @RenderBody()
        </div>
    </div>
</body>
@if (TempData["msgbox"] != null)
{ 
    <script type="text/javascript">
            $(function(){
                @Html.Raw(TempData["msgbox"] as string)
            });
    </script>
}
</html>
